<%@page import="sun.font.CreatedFontTracker"%>
<%@ page contentType="text/html" pageEncoding="UTF-8"%>
<% response.setContentType("text/html; charset=UTF-8");%>
<% request.setCharacterEncoding("utf-8");%>
<%@page import="controller.ModuleImportExportQuestionController, dto.CauHoiDTO" %>

<%
    String filename = "files/cauhoi_" + request.getParameter("t") + ".xml";
    String path = getServletContext().getRealPath("/") + filename;

    ModuleImportExportQuestionController ctrl = new ModuleImportExportQuestionController();

    try {
        boolean result = ctrl.exportQuestion(path);
        if (result == true) {
            out.print("<a href='" + filename + "'>link download</a>");
        } else {
            out.print("Đã có lỗi trong quá trình export");
        }
    } catch (Exception e) {
    }
%>